package jdbc;


import java.sql.Connection;
import java.sql.DriverManager;

public class ConnectionFactory {

	public Connection getConnection() {
		try {

			Class.forName("com.mysql.jdbc.Driver");
			return DriverManager.getConnection(
					"jdbc:mysql://localhost/vendas_fac", "root", "rooter");
		} catch (Exception e) {
			throw new RuntimeException(e);
		}// fim try catch.

	}// fim getConnection.
}// fim da classe.

